True if this instance’s whole collision box, standing at (x, y), would touch a wall of the room: a full collision square or an obstacle the room has. The edge of the room is not a wall. A slope is never a wall. It is tile_free’s answer with the ramps left out, for code that asks "is that a wall beside me?" and must not take a ramp for one.
tile_wall(x, y) -> bool| Name | Type |
|---|---|
x | real |
y | real |
bool
True if this instance's whole box, standing at (x, y), would touch a wall of the room. It is tile_free with the ramps left out: use it to ask "is that a wall beside me?" when a ramp beside you must not count.
x and y are a place in the room, counted from the room's top-left corner, the same way this instance's own x and y are counted. Nothing moves.
tile_free.tile_free. Ask pos_free about those.It asks what tile_free asks (a box that touches a slope is asked on its feet, see Slopes) with the pixels of the slopes left out. So a box beside or on a ramp is not at a wall, and the full squares that fill the ground under a ramp do not make one, unless a full square or an obstacle is really in the way.
In a game with no slopes tile_wall(x, y) answers exactly what !tile_free(x, y) answers, and costs the same.
The Player movement tab asks it for you: Wall slide and Wall jump look for a wall two pixels to the side of the player with tile_wall, and also for the solid objects the design names.
if (tile_wall(x + 2, y)) {
hsp = 0;
}Stops sideways speed when a wall, and not a ramp, is just to the right.
Asks the same box as tile_free. The kinds that count: a solid or low cover square with no shape (a full square), a placed obstacle, and the outside of the map. A square with a shape (SHAPE_45_FLOOR_UP_RIGHT and the rest, or a shape you drew yourself) never counts, whatever its steepness: the solid pixels of a ramp are not asked, so a box touching only ramps is not at a wall. Solid objects are not part of it, as they are not part of tile_free (use pos_free). In a game with no slopes it answers exactly what !tile_free(x, y) answers and costs the same: the shape part of the engine is compiled only for a game that has slopes. It asks the question tile_free asks, a body on its feet while its box touches a slope, with the pixels of the slopes left out: the full squares under a ramp’s line beside the feet do not count, as they do not stop a walker. The player’s wall slide and wall jump (Player movement) ask it a couple of pixels to the side.